﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

using System.Reflection;
using System.Threading;

namespace SalesVMT
{
    public partial class frmSplash : Form
    {
        public frmSplash(string status)
        {
            InitializeComponent();
            lblStatus.Text = status;
            Version v = Assembly.GetExecutingAssembly().GetName().Version;
            lblVersion.Text = "Phiên bản " + v.Major + "." + v.MajorRevision + "." + v.Minor + "." + v.MinorRevision;
        }

        private void bgWorker_DoWork(object sender, DoWorkEventArgs e)
        {
            Thread.Sleep(1500);
        }

        private void bgWorker_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            this.Close();
        }

        private void frmSplash_Load(object sender, EventArgs e)
        {
            bgWorker.RunWorkerAsync();
        }



    }
}